package com.huizu.api.service;

import java.util.List;
import java.util.Map;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.transaction.annotation.Transactional;

import com.huizu.api.domain.Coupon;
import com.huizu.api.domain.GoodType;
import com.huizu.api.domain.Spec1Api;

/**
 * 会员信息Service接口
 *
 * @date 2021-09-14
 */
public interface IShopApiService {

	// 轮播图
	public List<String> getRelation(Map<String, Object> map);

	// 一级商品类型
	public List<GoodType> getgoodType(Map<String, Object> param);

	// 二级商品类型
	public List<GoodType> getTwogoodType(Map<String, Object> param);

	// 推荐门店
	public List<Map<String, Object>> getShopList(Map<String, Object> param);

	// 门店详情
	public Map<String, Object> getShopDetail(Map<String, Object> map);

	// 推荐商品
	public List<Map<String, Object>> getGoodsByShopId(Map<String, Object> param);

	// 查询商品
	public List<Map<String, Object>> queryGoods(Map<String, Object> param);

	// 种类商品列表
	public List<Map<String, Object>> queryGoodsByCate(Map<String, Object> param);

	// 商品详情
	public Map<String, Object> getGoodsDetail(Map<String, Object> map);

	// 搜索排行及历史
	public Map<String, Object> getSearchHis(Map<String, Object> param);

	// 获取商品规格
	public List<Spec1Api> getSpec(Map<String, Object> param);

	// 价格查询
	public float getSpecPrice(Map<String, Object> map);

	// 购物车操作
	public int insertCart(Map<String, Object> map);

	// 修改购物车数量
	public int updateCartNum(Map<String, Object> map);

	// 购物车列表
	public List<Map<String, Object>> getCartList(Map<String, Object> map);

	// 删除购物车
	public void removeCart(Map<String, Object> map);

	// 地址信息

	public int insertAddress(Map<String, Object> map);

	public List<Map<String, Object>> getAddressList(Map<String, Object> map);

	public Map<String, Object> getAddress(Map<String, Object> map);

	public int deleteAddress(Map<String, Object> map);

	public int updateDefaultFlag(Map<String, Object> map);

	// 订单操作

	public Map<String, Object> insertOrder(Map<String, Object> map, HttpServletRequest request) throws Exception;

	// 支付宝回调
	public Map<String, Object> alipayCallbackUrl(HttpServletRequest request) throws Exception;

	// 微信回调
	public void WxcallbackUrl(HttpServletRequest request, HttpServletResponse response) throws Exception;

	public List<Map<String, Object>> getOrderList(Map<String, Object> map);

	public Map<String, Object> payOrder(Map<String, Object> map, HttpServletRequest request) throws Exception;

	public Map<String, Object> palipayCallbackUrl(HttpServletRequest request) throws Exception;

	public void pWxcallbackUrl(HttpServletRequest request, HttpServletResponse response) throws Exception;

	public int updateOrderStatusBySub(Map<String, Object> map);

	public int deleteOrder(Map<String, Object> map);

	public int returnOrder(Map<String, Object> map);

	public Map<String, Object> returnPrice(Map<String, Object> param) throws Exception;

	// 未领取优惠卷列表
	public List<Coupon> getShopCoupon(Map<String, Object> map);

	// 领取优惠卷
	public Map<String, Object> insertMemberCoupon(Map<String, Object> param);

	// 优惠卷列表
	public List<Coupon> getMemberCouponNum(Map<String, Object> map);

	// 会员商品收藏
	public void updateCollect(Map<String, Object> map);

	// 会员商品浏览记录
	public void insertBrowsing(Map<String, Object> map);

}
